package com.lichuang.dedao.ebook.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.lichuang.dedao.ebook.entity.EBook1;
import com.lichuang.dedao.ebook.mapper.EBookMapper;
import com.lichuang.dedao.ebook.service.IEBookService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 电子书 服务实现类
 * </p>
 *
 * @author miaomiao
 * @since 2019-07-12
 */
@Service
public class EBookServiceImpl extends ServiceImpl<EBookMapper, EBook1> implements IEBookService {


    @Override
    public List<EBook1> selectIEBooks() {
        return baseMapper.selectList(new QueryWrapper<>());
    }

    @Override
    public List<EBook1> selectIEBooksByName(String name) {
        QueryWrapper wrapper=new QueryWrapper();
        wrapper.like("name",name);
        return baseMapper.selectList(wrapper);
    }

}
